package dq.study.dockerdemo;

import org.springframework.beans.factory.annotation.Value;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author dongqun
 * @date 2020/8/26 14:33
 */
@RestController
public class TestController {
    @Value("${docker.demo.key1}")
    private String key1;
    @Value("${docker.demo.key2}")
    private String key2;
    @Value("${docker.demo.key3}")
    private String key3;


    @GetMapping("/")
    public String test(){
        return "hello Docker!";
    }

    @GetMapping("/k1")
    public String test1(){
        return key1;
    }

    @GetMapping("/k2")
    public String test2(){
        return key2;
    }


    @GetMapping("/k3")
    public String test3(){
        return key3;
    }
}
